home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
X User Tools
/
X User Tools (O'Reilly and Associates)(1994).ISO
/
sun4c
/
archive
/
tcltk.z
/
tcltk
/
man
/
catn
/
tk.n
< prev
next >
Wrap
Text File
|
1994-09-20
|
2KB
|
67 lines
tk(n) Tk Commands
_________________________________________________________________
NAME
tk - Manipulate Tk internal state
SYNOPSIS
tk _o_p_t_i_o_n ?_a_r_g _a_r_g ...?
_________________________________________________________________
DESCRIPTION
The tk command provides access to miscellaneous elements of
Tk's internal state. Most of the information manipulated by
this command pertains to the application as a whole, or to a
screen or display, rather than to a particular window. The
command can take any of a number of different forms depend-
ing on the _o_p_t_i_o_n argument. The legal forms are:
tk colormodel _w_i_n_d_o_w ?_n_e_w_V_a_l_u_e?
If _n_e_w_V_a_l_u_e isn't specified, this command returns the
current color model in use for _w_i_n_d_o_w's screen, which
will be either color or monochrome. If _n_e_w_V_a_l_u_e is
specified, then it must be either color or monochrome
or an abbreviation of one of them; the color model for
_w_i_n_d_o_w's screen is set to this value.
The color model is used by Tk and its widgets to deter-
mine whether it should display in black and white only
or use colors. A single color model is shared by all
of the windows managed by one process on a given
screen. The color model for a screen is set initially
by Tk to monochrome if the display has four or fewer
bit planes and to color otherwise. The color model
will automatically be changed from color to monochrome
if Tk fails to allocate a color because all entries in
the colormap were in use. An application can change
its own color model at any time (e.g. it might change
the model to monochrome in order to conserve colormap
entries, or it might set the model to color to use
color on a four-bit display in special circumstances),
but an application is not allowed to change the color
model to color unless the screen has at least two bit
planes.
KEYWORDS
color model, internal state
Tk 1